Return to start page
Core/Maths/Library Location.j
1 library ALibraryCoreMathsLocation requires ALibraryCoreMathsPoint
2
3 /// @return Returns the distance between location @param location0 and @param location1.
4 /// Benutzt im Gegensatz zur originalen Funktion den Z-Wert.
5 function GetDistanceBetweenLocations takes location location0, location location1 returns real
6 return GetDistanceBetweenPoints(GetLocationX(location0), GetLocationY(location0), GetLocationZ(location0), GetLocationX(location1), GetLocationY(location1), GetLocationZ(location1))
7 endfunction
8
9 /// @return Returns the centre location between location @param location0 and @param location1.
10 /// Achtung: Z muss ignoriert werden, da sich kein Punkt mit einem Z-Wert erstellen lässt.
11 function GetCentreBetweenLocations takes location location0, location location1 returns location
12 return GetCentreBetweenPoints(GetLocationX(location0), GetLocationY(location0), GetLocationX(location1), GetLocationY(location1))
13 endfunction
14
15 /// @return Returns the angle between location @param location0 and @param location1 from centre location @param centre.
16 function GetAngleBetweenLocationsFromCentre takes location centre, location location0, location location1 returns real
17 return GetAngleBetweenPointsFromCentre(GetLocationX(centre), GetLocationY(centre), GetLocationX(location0), GetLocationY(location0), GetLocationX(location1), GetLocationY(location1))
18 endfunction
19
20 endlibrary